//Klimov Ivan
// Saint Petersburg State University, 361 gr.
// 2013 (c)
extern "C" __global__ void createStartStoreKernel(int *Store, int scaleExp, int scaleM, int scaleVar)
{
	int row = blockDim.y*blockIdx.y + threadIdx.y;
	int column = blockDim.x*blockIdx.x + threadIdx.x;

	if(row < scaleExp && column < scaleM) {
		if(row < scaleVar) {
			if(column % scaleM == 0) {
				Store[row*scaleM + column] = 1;
			} else {
				Store[row*scaleM + column] = -1;
			}
		} else {
			if(column == 0) {
				Store[row*scaleM + column] = 2;
			} else if(column == 1) {
				Store[row*scaleM + column] = row - scaleVar + 1;
			} else {
				Store[row*scaleM + column] = -1;
			}
		}
	}
}